<!-- head -->
{include file='public/head' /}
<!-- head -->

<!-- left -->
{include file='public/left' /}
<!-- left -->

<div class="content-wrapper">
    <!-- Content Header (Page header) -->
    <section class="content-header">
        <h1>
            客户信息
        </h1>
        <ol class="breadcrumb">
            <li><a href="#"><i class="fa fa-dashboard"></i> 人员管理</a></li>
            <li><a href="#">用户列表</a></li>
            <li class="active">查看信息</li>
        </ol>
    </section>

    <!-- Main content -->
    <section class="content">

        <div class="row">
            <div class="col-md-3">
                <!-- Widget: user widget style 1 -->
                <div class="box box-widget widget-user">
                    <!-- Add the bg color to the header using any of the bg-* classes -->
                    <div class="widget-user-header bg-black" style="background: url('__STATIC__/AdminLTE/dist/img/photo1.png') center center;">
                        <h3 class="widget-user-username">
                            {if condition="$custominfo.custom_name neq ''"} {$custominfo.custom_name}
                            {elseif condition="$custominfo.real_name neq ''"/}{$custominfo.real_name}
                            {else /} {$custominfo.custom_phone}
                            {/if}
                        </h3>
                        <h5 class="widget-user-desc"></h5>
                    </div>
                    <div class="widget-user-image">
                        <img class="img-circle" src="__STATIC__/AdminLTE/dist/img/user3-128x128.jpg" alt="User Avatar">
                        <!--                        <img class="img-circle" src="/../kkmimg/{$custominfo.custom_photo}" alt="User Avatar">-->
                    </div>
                    <div class="box-footer">
                        <div class="row">
                            <div class="col-sm-4 border-right">
                                <div class="description-block">
                                    <h5 class="description-header">{$custominfo.consume_money}</h5>
                                    <span class="description-text">消费金额</span>
                                </div>
                                <!-- /.description-block -->
                            </div>
                            <!-- /.col -->
                            <div class="col-sm-4 border-right">
                                <div class="description-block">
                                    <h5 class="description-header">{$custominfo.service_count}</h5>
                                    <span class="description-text">进店次数</span>
                                </div>
                                <!-- /.description-block -->
                            </div>
                            <!-- /.col -->
                            <div class="col-sm-4">
                                <div class="description-block">
                                    <h5 class="description-header">{$custominfo.residue_ingt}</h5>
                                    <span class="description-text">积分</span>
                                </div>
                                <!-- /.description-block -->
                            </div>
                            <!-- /.col -->
                        </div>
                        <!-- /.row -->

                        <ul class="list-group list-group-unbordered">
                            <li class="list-group-item">
                                <b>美容师</b> <a class="pull-right">{$custominfo.staff.staff_name}</a>
                            </li>
                            <li class="list-group-item">
                                <b>访问次数</b> <a class="pull-right">{$custominfo.visit_count}</a>
                            </li>
                            <li class="list-group-item">
                                <b>手机号</b> <a class="pull-right">{$custominfo.custom_phone}</a>
                            </li>
                            <li class="list-group-item">
                                <b>性别</b> <a class="pull-right">{if condition="$custominfo.custom_sex eq 1"} 男{else /} 女{/if}</a>
                            </li>
                            <li class="list-group-item">
                                <b>客户类型</b> 
                                <a class="pull-right">
                                    {if condition="$custominfo.vip_status eq 0"} 访客用户
                                    {elseif condition="$custominfo.vip_status eq 1"/}普通用户
                                    {elseif condition="$custominfo.vip_status eq 2"/}vip用户
                                    {/if}
                                </a>
                            </li>
                            <li class="list-group-item">
                                <b>最后访问时间</b> <a class="pull-right">{$custominfo.visit_time|date='Y-m-d H:i',###}</a>
                            </li>
                            <li class="list-group-item">
                                <b>更新时间</b> <a class="pull-right">{$custominfo.update_time}</a>
                            </li>
                            <li class="list-group-item">
                                <b>注册时间</b> <a class="pull-right">{$custominfo.add_time|date='Y-m-d H:i',###}</a>
                            </li>
                        </ul>

                    </div>
                </div>
                <!-- /.widget-user -->
            </div>
            <!-- /.col -->
            <div class="col-md-9">
                <div class="nav-tabs-custom">
                    <ul class="nav nav-tabs">
                        <li><a href="{:url('Custom/ShowMessage',['id'=>$id])}">订单信息</a></li>
                        <li class="active"><a href="{:url('Custom/ShowOnlineMessage',['id'=>$id])}">预约信息</a></li>
                    </ul>
                    <div class="tab-content">
                        <!------预约信息------->
                        <div class="active tab-pane" id="item">
                            <div class="row">
                                <div class="col-sm-12">
                                    <div class="box box-primary">
                                        <div class="box-header with-border">
                                            <h3 class="box-title" style="font-size: 14px;">共计{$onlineList->total()}条记录</h3>
                                            <div class="box-tools pull-right">
                                                <button type="button" class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i>
                                                </button>
                                                <button type="button" class="btn btn-box-tool" data-widget="remove"><i class="fa fa-times"></i></button>
                                            </div>
                                        </div>
                                        <div class="box-body">
                                            <div class="table-responsive">
                                                <table class="table table-bordered table-striped">
                                                    <thead>
                                                        <tr>
                                                            <th>编号</th>
                                                            <th>用户名称</th>
                                                            <th>服务项目</th>
                                                            <th>美容师</th>
                                                            <th>预约状态</th>
                                                            <th>服务时间</th>
                                                            <th>预约时间</th>
                                                        </tr>
                                                    </thead>
                                                    <tbody>
                                                        {volist name='onlineList' id='admin'}
                                                        <tr>
                                                            <td>{$admin.id}</td>
                                                            <td>
                                                                {if condition="$admin.custom.real_name neq ''"}{$admin.custom.real_name}
                                                                {elseif condition="$admin.custom.custom_name neq ''"/}{$admin.custom.custom_name}
                                                                {elseif condition="$admin.custom.custom_phone neq ''"/}{$admin.custom.custom_phone}
                                                                {/if}
                                                            </td>
                                                            <td>{$admin.item.item_name}</td>
                                                            <td>{$admin.staff.staff_name}</td>
                                                            <td>
                                                                {if condition="$admin.status eq 1"}待服务
                                                                {elseif condition="$admin.status eq 2"/}服务中
                                                                {elseif condition="$admin.status eq 3"/}已完成
                                                                {elseif condition="$admin.status eq 4"/}已取消
                                                                {/if}
                                                            </td>
                                                            <td>{$admin.start_time|date='Y-m-d H:i',###}</td>
                                                            <td>{$admin.add_time|date='Y-m-d H:i',###}</td>
                                                        </tr>
                                                        {/volist}
                                                    </tbody>
                                                </table>
                                            </div>
                                        </div>
                                        <div class="box-footer clearfix" style="text-align: center">
                                            {$onlineList->render()}
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <!------预约信息结束------->
                    </div>
                    <!-- /.tab-content -->
                </div>
                <!-- /.nav-tabs-custom -->
            </div>
            <!-- /.col -->
        </div>
        <!-- /.row -->

    </section>
    <!-- /.content -->
</div>
<script type="text/javascript">
    function OrderDetails(obj) {
        var url = $(obj).data('url');
        window.location.href = url;
    }
</script>
<!-- foot -->
{include file='public/foot' /}
<!-- foot -->